#include <iostream>

const int ArSize = 15;

int main()
{
    using namespace std;

    long long factorials[ArSize];
    factorials[1] = factorials[0] = 1;

    for (int i = 2; i < ArSize; i++)
        factorials[i] = factorials[i - 1] * i;

    for (int i = 0; i < ArSize; i++)
        cout << i << "! = " << factorials[i] << endl;

    return 0;
}